import request2 from '@/utils/request2'
import { materialApiUrl } from '../../config'


export default {
  // /物资盘点计划-新增
  createByMain(data, params) {
    return request2({
      url: materialApiUrl + '/materials/inventory_plan/createByMain', method: 'post', params, data
    })
  },
  // /物资盘点计划-编辑
  editByMain(data, params) {
    return request2({
      url: materialApiUrl + '/materials/inventory_plan/editByMain', method: 'post', params, data
    })
  },
  // /物资盘点计划-列表搜索
  findListByMain(data, params) {
    return request2({
      url: materialApiUrl + '/materials/inventory_plan/findListByMain', method: 'post', params, data
    })
  },
  // 物资盘点计划-统计
  count(data, params) {
    return request2({
      url: materialApiUrl + '/materials/inventory_plan/count', method: 'post', params, data
    })
  },
  // 物资盘点计划-打印
  print(data, params) {
    return request2({
      url: materialApiUrl + '/materials/inventory_plan/print/' + params.id, method: 'get', params, data
    })
  },
  // 物资盘点计划-删除
  deleteById( params) {
    return request2({
      url: materialApiUrl + '/materials/inventory_plan/deleteById/' + params.id, method: 'get', params
    })
  },
  // 物资盘点计划-id查询详情
  findById(data, params) {
    return request2({
      url: materialApiUrl + '/materials/inventory_plan/findById/' + params.id, method: 'get', params, data
    })
  }
}